﻿@model JuniorProject.Models.Employee.CreationModels.Create_QuestionModel

@{
    ViewBag.Title = "AddQuestion";
}

@section scripts
{
    <link href="@Url.Content("~/Content/themes/base/jquery-tablesorter.css")" rel="stylesheet" type="text/css" />
    <script src="@Url.Content("~/Scripts/jquery.tablesorter.js")" type="text/javascript"></script>
    <script type="text/javascript">
        $(function () {
            $('table').tablesorter({ headers: { 2: { sorter: false} }, sortList: [[0, 0]] });
        });
    </script>
}

<h2>Add New Screening Question</h2>
<br />

@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)

    <fieldset>
        <legend>Create_JobModel</legend>

        <div class="editor-label">
            @Html.LabelFor(model => model.Question)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Question)
            @Html.ValidationMessageFor(model => model.Question)
        </div>

        <table id="table" class="tablesorter">
            <thead>
                <tr>
                    <th>
                        @Html.DisplayNameFor(model => model.Answers[0].ID)
                    </th>
                    <th>
                        @Html.DisplayNameFor(model => model.Answers[0].Answer)
                    </th>
                </tr>
            </thead>
            <tbody>
                @Html.EditorFor(m => m.Answers)
            </tbody>

        </table>

        <p>
            <input type="submit" value="Create" />
        </p>
    </fieldset>
}

@Html.ActionLink("Back to List", "Jobs" )
<p>
    @Html.Partial("_EmployeeBottomNavBar", ViewData["AccessLevel"])
</p>